# -*- coding: utf-8 -*-
"""
Created on Sun Mar 26 13:06:10 2023

@author: lenovo
"""

# =============================================================================
# class Calculator:
#     
#     def add(self, a, b):
#         return a + b
#     
#     def subtract(self, a, b):
#         return a - b
#     
#     def multiply(self, a, b):
#         return a * b
#     
#     def divide(self, a, b):
#         if b == 0:
#             return "Error: division by zero"
#         else:
#             return a / b
# =============================================================================
class Calculator:
    
    def add(self, a, b):
        return a + b
    
    def subtract(self, a, b):
        return a - b
    
    def multiply(self, a, b):
        return a * b
    
    def divide(self, a, b):
        if b == 0:
            return "Error: division by zero"
        else:
            return a / b
    
    def exponent(self, a, b):
        return a ** b